package com.yangyouqi.posthorse.core.repository;

import com.yangyouqi.posthorse.core.domain.Customer;
import com.yangyouqi.posthorse.core.domain.Order;
import org.springframework.data.domain.Page;
import org.springframework.data.domain.Pageable;
import org.springframework.data.jpa.repository.JpaRepository;

/**
 * @author 杨友奇
 * @Time 2018/6/5
 */
public interface OrderRepository extends JpaRepository<Order,Long> {
    public Page<Order> findByCreator(Customer creator, Pageable pageable);

    public Page<Order> findByDesignee(Customer designee, Pageable pageable);
}

